package com.goodwin.deity.desktop.domain;

import javafx.beans.property.SimpleStringProperty;

import java.awt.*;
import java.io.File;
import java.util.HashMap;

/**
 * Created by GOODWIS4 on 12/30/2014.
 */
public class ImageEntry {

    private File file;
    private Color[][] signature;
    private HashMap<ImageEntry, String> relatedImages = new HashMap<>();

    public ImageEntry(File file, Color[][] signature) {
        this.file = file;
        this.setSignature(signature);
    }

    public File getFile() {
        return this.file;
    }

    public void setFile(File file) {
        this.file = file;
    }


    public SimpleStringProperty getSimpleFileName() {
        return new SimpleStringProperty(file.getName());
    }

    public HashMap<ImageEntry, String> getRelatedImages() {
        return relatedImages;
    }

    public void addRelatedImage(ImageEntry imageEntry, String difference) {
        this.relatedImages.put(imageEntry, difference);
    }

    public SimpleStringProperty getCountRelatedImages() {
        return new SimpleStringProperty(Integer.toString(relatedImages.size()));
    }

    public Color[][] getSignature() {
        return signature;
    }

    public void setSignature(Color[][] signature) {
        this.signature = signature;
    }


}
